home *** CD-ROM | disk | FTP | other *** search
/ VRML 2.0 Sourcebook (2nd Edition) / VRML 2.0 Sourcebook CD [md5 fed90f4f9c39d5a60d477058775c7e21].iso / book / unix / ch20 / 20fig17b.wrl < prev    next >
Text File  |  1996-09-23  |  2KB  |  98 lines

  1. #VRML V2.0 utf8
  2. # The VRML 2.0 Sourcebook
  3. # Copyright [1997] By
  4. # Andrea L. Ames, David R. Nadeau, and John L. Moreland
  5. Group {
  6.     children [
  7.     # Lighting
  8.         DirectionalLight {
  9.             direction 0.0 -1.0 0.0
  10.             ambientIntensity 0.5
  11.         },
  12.     # Floor
  13.         Shape {
  14.             appearance Appearance {
  15.                 material Material { }
  16.             }
  17.             geometry Box { size 8.0 0.01 8.0 }
  18.         },
  19.     # Spheres and fake shadows
  20.         Transform {
  21.             translation 0.0 4.0 2.0
  22.             children [
  23.                 Shape {
  24.                     appearance Appearance {
  25.                         material Material { diffuseColor 1.0 1.0 0.0 }
  26.                     }
  27.                     geometry Sphere { }
  28.                 },
  29.             # Shadow
  30.                 Transform {
  31.                     translation 0.0 -3.95 0.0
  32.                     children Shape {
  33.                         appearance DEF ShadowAppearance Appearance {
  34.                             material Material {
  35.                                 diffuseColor 0.0 0.0 0.0
  36.                                 transparency 0.5
  37.                             }
  38.                         }
  39.                         geometry Cylinder {
  40.                             height 0.0
  41.                             side   FALSE
  42.                             bottom FALSE
  43.                         }
  44.                     }
  45.                 }
  46.             ]
  47.         },
  48.         Transform {
  49.             translation 2.0 2.0 -2.0
  50.             children [
  51.                 Shape {
  52.                     appearance Appearance {
  53.                         material Material { diffuseColor 0.0 1.0 0.0 }
  54.                     }
  55.                     geometry Sphere { radius 2.0 }
  56.                 },
  57.             # Shadow
  58.                 Transform {
  59.                     translation 0.0 -1.95 0.0
  60.                     children Shape {
  61.                         appearance USE ShadowAppearance
  62.                         geometry Cylinder {
  63.                             radius 2.0
  64.                             height 0.0
  65.                             side   FALSE
  66.                             bottom FALSE
  67.                         }
  68.                     }
  69.                 }
  70.             ]
  71.         },
  72.         Transform {
  73.             translation -2.0 2.5 0.0
  74.             children [
  75.                 Shape {
  76.                     appearance Appearance {
  77.                         material Material { diffuseColor 0.0 1.0 1.0 }
  78.                     }
  79.                     geometry Sphere { radius 0.75 }
  80.                 },
  81.             # Shadow
  82.                 Transform {
  83.                     translation 0.0 -2.45 0.0
  84.                     children Shape {
  85.                         appearance USE ShadowAppearance
  86.                         geometry Cylinder {
  87.                             radius 0.75
  88.                             height 0.0
  89.                             side   FALSE
  90.                             bottom FALSE
  91.                         }
  92.                     }
  93.                 }
  94.             ]
  95.         }
  96.     ]
  97. }
  98.